#include "widget.h"
#include "ui_widget.h"
#include <QPushButton>
#include <QDebug>

Widget::Widget(QWidget *parent)
    : QWidget(parent)
    , ui(new Ui::Widget)
{
    srand(time(nullptr));
    ui->setupUi(this);
}

Widget::~Widget()
{
    delete ui;
}

void Widget::on_pushButton_accept_clicked()
{
    ui->label->setText("好的");
}


void Widget::on_pushButton_reject_pressed()
{
    int x = rand() % this->geometry().width();
    int y = rand() % this->geometry().height();
    ui->pushButton_reject->move(x, y);
}

